package org.focusj.scala.clazz

import java.util.Random

class Counter {
    def getInt = Counter.getRandInt
    def getLong = Counter.getRandLong
    def getDouble = Counter.getRandDouble
}

object Counter {
    private[this] val rand = new Random
    private def getRandInt() = rand.nextInt()
    private def getRandLong() = rand.nextLong()
    private def getRandDouble() = rand.nextDouble()
}